﻿using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.AI;
public class MoveController : MonoBehaviour {
    NavMeshAgent agent;
    // Use this for initialization
    void Start()
    {
        agent = GetComponent<NavMeshAgent>();
    }

    // Update is called once per frame
    void Update()
    {

    }
    public void MoveAgent(Vector3 pos)
    {
        agent.destination = pos;
    }
    public bool IsOver()
    {
        if (agent.remainingDistance == 0)
        {
            return true;
        }
        return false;
    }
}
